﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Brain
{
    public static class ConversionUtil
    {
        public static float MillisecondToSecond(float milliseconds)
        {
            return milliseconds / 1000f;
        }
        public static float SecondToMillisecond(float seconds)
        {
            return seconds * 1000f;
        }

        public static float FrameToMillisecond(float frame, float TimeStep)
        {
            //float timeStep = ((1 / (float)TimeStep) * 1000);
            return frame * TimeStep;
        }
        public static float FrameToSecond(float frame, float TimeStep)
        {
            //float timeStep = ((1 / (float)TimeStep) * 1000);
            float sec = MillisecondToSecond(TimeStep);
            return frame * sec;
        }
    }
}
